# Maintainer: Alexander F. Rødseth <xyproto@archlinux.org>

pkgname=netsurf-buildsystem
pkgver=1.9
pkgrel=3
pkgdesc='The Netsurf buildsystem'
arch=(any)
url='https://source.netsurf-browser.org/buildsystem.git'
license=(MIT)
source=("$pkgname-$pkgver.tar.bz2::https://source.netsurf-browser.org/buildsystem.git/snapshot/buildsystem-release/$pkgver.tar.bz2")
sha256sums=('9689085bda4b4110cbbb2034eb19f27b0c5f77f7998029be5a18d61f4d32a336')

build() {
  cd "buildsystem-release/$pkgver"
  sed -i 's:-Werror::' Makefile
  make PREFIX=/usr COMPONENT_TYPE=lib-shared
  make PREFIX=/usr COMPONENT_TYPE=lib-static
}

package() {
  cd "buildsystem-release/$pkgver"
  make install PREFIX=/usr DESTDIR="$pkgdir" COMPONENT_TYPE=lib-shared
  make install PREFIX=/usr DESTDIR="$pkgdir" COMPONENT_TYPE=lib-static
  install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"
}

# getver: git.netsurf-browser.org/buildsystem.git/plain/Makefile
# vim: ts=2 sw=2 et:
